﻿using System;
using System.Collections;
using System.Configuration;
using System.Data;
using System.Linq;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using System.Xml.Linq;

public partial class MasterPage_User : System.Web.UI.MasterPage
{
    UserMaster um = new UserMaster();
    protected void Page_Load(object sender, EventArgs e)
    {
        gvTheLoai.DataSource = um.gv_TheLoai();
        gvTheLoai.DataBind();

        gvHangSanXuat.DataSource = um.gv_HangSanXuat();
        gvHangSanXuat.DataBind();

        gvPhimMoi.DataSource = um.gv_PhimMoi();
        gvPhimMoi.DataBind();

        dlQuangCao.DataSource = um.dl_QuangCao();
        dlQuangCao.DataBind();
        
    }
    protected void Button1_Click(object sender, EventArgs e)
    {
        Response.Redirect("Phim.aspx?idphim=" +txtTim.Text);
    }
    protected void gvTheLoai_RowCommand(object sender, GridViewCommandEventArgs e)
    {
        Response.Redirect("TimTheLoai.aspx?idtl=" + e.CommandArgument.ToString());
    }
    protected void gvHangSanXuat_RowCommand(object sender, GridViewCommandEventArgs e)
    {
        Response.Redirect("TimHSX.aspx?id=" + e.CommandArgument.ToString());
    }
    protected void gvPhimMoi_RowCommand(object sender, GridViewCommandEventArgs e)
    {
        Response.Redirect("ChiTietPhim.aspx?id=" + e.CommandArgument.ToString());
    }
}
